POST
/
v1
/
flux-pro-finetuned
curl --request POST \
  --url https://api.us1.bfl.ai/v1/flux-pro-finetuned \
  --header 'Content-Type: application/json' \
  --header 'x-key: <api-key>' \
  --data '{
  "finetune_id": "my-finetune",
  "finetune_strength": 1.1,
  "steps": 40,
  "guidance": 2.5,
  "prompt": "ein fantastisches bild",
  "image_prompt": "<string>",
  "width": 1024,
  "height": 768,
  "prompt_upsampling": false,
  "seed": 42,
  "safety_tolerance": 2,
  "output_format": "jpeg",
  "webhook_url": "<string>",
  "webhook_secret": "<string>"
}'
{
  "id": "<string>",
  "polling_url": "<string>"
}

Authorizations

x-key
string
header
required

Body

application/json
finetune_id
string
required

ID of the fine-tuned model you want to use.

Example:

"my-finetune"

finetune_strength
number
default:1.1

Strength of the fine-tuned model. 0.0 means no influence, 1.0 means full influence. Allowed values up to 2.0

Required range: 0 <= x <= 2
steps
integer
default:40

Number of steps for the fine-tuning process.

Required range: 1 <= x <= 50
Example:

40

guidance
number
default:2.5

Guidance scale for image generation. High guidance scales improve prompt adherence at the cost of reduced realism.

Required range: 1.5 <= x <= 5
Example:

2.5

prompt
string
default:""

Text prompt for image generation.

Example:

"ein fantastisches bild"

image_prompt
string | null

Optional base64 encoded image to use with Flux Redux.

width
integer
default:1024

Width of the generated image in pixels. Must be a multiple of 32.

Required range: 256 <= x <= 1440Must be a multiple of 32
height
integer
default:768

Height of the generated image in pixels. Must be a multiple of 32.

Required range: 256 <= x <= 1440Must be a multiple of 32
prompt_upsampling
boolean
default:false

Whether to perform upsampling on the prompt. If active, automatically modifies the prompt for more creative generation.

seed
integer

Optional seed for reproducibility.

Example:

42

safety_tolerance
integer
default:2

Tolerance level for input and output moderation. Between 0 and 6, 0 being most strict, 6 being least strict.

Required range: 0 <= x <= 6
Example:

2

output_format
enum<string>

Output format for the generated image. Can be 'jpeg' or 'png'.

Available options:
jpeg,
png
webhook_url
string | null

URL to receive webhook notifications

Required string length: 1 - 2083
webhook_secret
string | null

Optional secret for webhook signature verification

Response

200
application/json

Successful Response

id
string
required
polling_url
string
required
POST
/
v1
/
flux-pro-finetuned
curl --request POST \
  --url https://api.us1.bfl.ai/v1/flux-pro-finetuned \
  --header 'Content-Type: application/json' \
  --header 'x-key: <api-key>' \
  --data '{
  "finetune_id": "my-finetune",
  "finetune_strength": 1.1,
  "steps": 40,
  "guidance": 2.5,
  "prompt": "ein fantastisches bild",
  "image_prompt": "<string>",
  "width": 1024,
  "height": 768,
  "prompt_upsampling": false,
  "seed": 42,
  "safety_tolerance": 2,
  "output_format": "jpeg",
  "webhook_url": "<string>",
  "webhook_secret": "<string>"
}'
{
  "id": "<string>",
  "polling_url": "<string>"
}

Authorizations

x-key
string
header
required

Body

application/json
finetune_id
string
required

ID of the fine-tuned model you want to use.

Example:

"my-finetune"

finetune_strength
number
default:1.1

Strength of the fine-tuned model. 0.0 means no influence, 1.0 means full influence. Allowed values up to 2.0

Required range: 0 <= x <= 2
steps
integer
default:40

Number of steps for the fine-tuning process.

Required range: 1 <= x <= 50
Example:

40

guidance
number
default:2.5

Guidance scale for image generation. High guidance scales improve prompt adherence at the cost of reduced realism.

Required range: 1.5 <= x <= 5
Example:

2.5

prompt
string
default:""

Text prompt for image generation.

Example:

"ein fantastisches bild"

image_prompt
string | null

Optional base64 encoded image to use with Flux Redux.

width
integer
default:1024

Width of the generated image in pixels. Must be a multiple of 32.

Required range: 256 <= x <= 1440Must be a multiple of 32
height
integer
default:768

Height of the generated image in pixels. Must be a multiple of 32.

Required range: 256 <= x <= 1440Must be a multiple of 32
prompt_upsampling
boolean
default:false

Whether to perform upsampling on the prompt. If active, automatically modifies the prompt for more creative generation.

seed
integer

Optional seed for reproducibility.

Example:

42

safety_tolerance
integer
default:2

Tolerance level for input and output moderation. Between 0 and 6, 0 being most strict, 6 being least strict.

Required range: 0 <= x <= 6
Example:

2

output_format
enum<string>

Output format for the generated image. Can be 'jpeg' or 'png'.

Available options:
jpeg,
png
webhook_url
string | null

URL to receive webhook notifications

Required string length: 1 - 2083
webhook_secret
string | null

Optional secret for webhook signature verification

Response

200
application/json

Successful Response

id
string
required
polling_url
string
required